// 路由规则
export default [{
        path: '/',
        redirect: '/home/dashboard'
    },
    {
        // 注册
        path: '/register',
        component: () =>
            import ('../views/register')
    },
    {
        // 登录
        path: '/login',
        component: () =>
            import ('../views/login')
    },
    {
        path: '/test',
        component: () =>
            import ("@/views/test")
    },
    {
        // 首页
        path: '/home',
        component: () =>
            import ('../views/home'),
        children: [
            // 首页
            {
                path: 'dashboard',
                title: '首页管理',
                icon: 'el-icon-orange',
                name: '/home/dashboard',
                component: () =>
                    import ('../views/dashboard'),
                meta: {
                    title: '首页管理',
                }
            },
            // 分类
            {
                path: 'category',
                title: '分类管理',
                icon: 'el-icon-menu',
                name: '/home/category',
                component: () =>
                    import ('../views/category'),
                meta: {
                    title: '分类管理',
                }
            },
            // 页面
            {
                path: 'page',
                title: '页面管理',
                icon: 'el-icon-notebook-1',
                name: '/home/page',
                component: () =>
                    import ('../views/page'),
                meta: {
                    title: '页面管理',
                }
            },
            // 客户
            {
                path: 'client',
                title: '客户管理',
                icon: 'el-icon-s-custom',
                name: '/home/client',
                component: () =>
                    import ('../views/client'),
                meta: {
                    title: '客户管理',
                }
            },
            // 经济
            {
                path: 'economics',
                title: '经纪管理',
                icon: 'el-icon-money',
                name: '/home/economics',
                component: () =>
                    import ('../views/economics'),
                meta: {
                    title: '经纪管理',
                }
            },
            // 房产
            {
                path: 'house',
                title: '房产管理',
                icon: 'el-icon-office-building',
                name: '/home/house',
                component: () =>
                    import ('../views/house'),
                meta: {
                    title: '房产管理',
                }
            }
        ]
    }
]